// SPDX-License-Identifier: GPL-2.0-or-later

#ifndef _SNAKE_APP_HPP_
#define _SNAKE_APP_HPP_

#include <Snake/Game.hpp>
#include <Snake/Field/AField.hpp>

#include <SFML/Graphics/RenderWindow.hpp>
#include <SFML/System/Clock.hpp>

class App
{
	private:
		sf::RenderWindow* window;
		sf::Clock clock;

		void update(sf::Time delta);
		void processEvents(sf::Time delta);

		void draw();
		void drawSnake();

		bool quit = false;

		Game* game;
		AField* field;

	public:
		App();

		void run();
};

#endif
